﻿using MongoDB.Bson.Serialization.Attributes;
using System;
using System.Collections.Generic;
using System.Text;

namespace AppSocketModel
{
    /// <summary>
    /// 车辆位置
    /// </summary>
    [BsonIgnoreExtraElements]
    public class LocationDto
    {
        /// <summary>
        /// 企业Id
        /// </summary>
        public int CompanyId { set; get; }

        /// <summary>
        /// 账户Id
        /// </summary>
        public string AccountId { set; get; }


        /// <summary>
        /// 车牌号
        /// </summary>
        public string VehicleNo { set; get; }

        /// <summary>
        /// GPS-IMEI
        /// </summary>
        public string IMEI { set; get; }

        /// <summary>
        /// 设备定位时间
        /// </summary>
        public DateTime? GpsTime { get; set; }
        /// <summary>
        /// 平台收到设备上报位置数据时的系统时间
        /// </summary>
        public DateTime? SysTime { get; set; }


        /// <summary>
        /// 经度
        /// </summary>
        public double Lng { get; set; }

        /// <summary>
        /// 经度半球 E或W（东经或西经）
        /// </summary>
        public string LngHemi { get; set; }
        /// <summary>
        /// 纬度
        /// </summary>
        /// 
        public double Lat { get; set; }

        /// <summary>
        /// 纬度半球，N或S（北纬或南纬）
        /// </summary>
        public string LatHemi { get; set; }
         
        /// <summary>
        /// 速度
        /// </summary>
        public double? Speed { get; set; }
        /// <summary>
        /// 航向
        /// </summary>
        public double? Course { get; set; }

        /// <summary>
        /// 定位方式
        /// </summary>
        public string Location { get; set; }
        
        /// <summary>
        /// 电池电压
        /// </summary>
        public float BatteryVoltage { set; get; }

        /// <summary>
        /// 唤醒类型
        /// </summary>
        public string WakeUpType { set; get; }

        /// <summary>
        /// 数据发送序号
        /// </summary>
        public int SendNo { get; set; }

        /// <summary>
        /// 数据帧长度
        /// </summary>
        public int Len { set; get; }


        /// <summary>
        /// 信号强度
        /// </summary>
        public int SingledBm { set; get; }


        /// <summary>
        /// 硬件类型
        /// </summary>
        public DeviceType deviceType { set; get; }

        /// <summary>
        /// 上次报警
        /// </summary>
        public DateTime? PreAlarmDateTime { set; get; }

        /// <summary>
        /// 设备在线状态
        /// </summary>
        public GpsDeviceOnlineState? GpsDeviceOnlineState { get; set; }

        /// <summary>
        /// 设备移动/静止状态
        /// </summary>
        public GpsDeviceSpeedState? GpsDeviceSpeedState { get; set; }

        /// <summary>
        /// 设备离线时间
        /// </summary>
        public OffLineTimeDto OffLineTime { set; get; }
    }
}
